package com.itheima.demo4;

public class ExceptionDemo1 {

    public static void main(String[] args) {

        int[] arr = {1,2,3,4,5,6};

        try {
            System.out.println(arr[10]);
        } catch (ArrayIndexOutOfBoundsException e) {
            e.printStackTrace();
        }

        //打印红色的字体信息

        System.err.println(arr[1]);

    }
}
